package com.shopcentre15.shopcentre.FormalShopExplot.Dao.Goods;

import com.shopcentre15.shopcentre.FormalShopExplot.Entity.ShopGoods;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;
import java.util.Map;

@Mapper
@Repository
public interface GoodsDao {
    Integer addProduct(Map<String,Object> params);

    List<ShopGoods> getGoodsList();

    List<ShopGoods> getGoodsListByPage(Map<String,Object> params);

    Integer getTotalGoodsCount(int mid);
    List<ShopGoods> getGoodsListByPageHelper(int mid);

    Integer UpdateProduct(@Param("id") int id,@Param("state") int state);

    ShopGoods goodInfo(int id);

    List<ShopGoods> getGoodsByTitle(@Param("keyword") String Keyword,@Param("mid") int mid);

    Integer updateGoodInfo(Map<String,Object> params);

    Integer UpdateGoodsStateBatch(List<Integer> mids);

}

